home *** CD-ROM | disk | FTP | other *** search
/ IRIX Base Documentation 1998 November / IRIX 6.5.2 Base Documentation November 1998.img / usr / share / catman / a_man / cat7 / serial.z / serial
Text File  |  1998-10-20  |  23KB  |  590 lines

  1.  
  2.  
  3.  
  4. sssseeeerrrriiiiaaaallll((((7777))))                                                            sssseeeerrrriiiiaaaallll((((7777))))
  5.  
  6.  
  7.  
  8. NNNNAAAAMMMMEEEE
  9.      serial - serial communication ports
  10.  
  11. SSSSYYYYNNNNOOOOPPPPSSSSIIIISSSS
  12.      ////ddddeeeevvvv////ttttttttyyyy<ttttyyyyppppeeee><ppppoooorrrrttttnnnnoooo>
  13.  
  14. DDDDEEEESSSSCCCCRRRRIIIIPPPPTTTTIIIIOOOONNNN
  15.      All Silicon Graphics systems have two or more general purpose serial
  16.      ports.  These ports can be used to connect terminals, printers, modems,
  17.      other systems, or graphical input devices such as a tablet or dial and
  18.      button box.  Each line can be independently set to run at any of several
  19.      speeds.  Various character echoing and interpreting parameters can also
  20.      be set.  See _s_t_t_y(1) and _t_e_r_m_i_o(7) for details on the various modes.
  21.  
  22.      Details of the serial ports found on optional add-on boards are given
  23.      elsewhere.  The Audio/Serial Option for CHALLENGE/Onyx provides six
  24.      high-speed serial ports, see _a_s_o_s_e_r(7) for more information.  The CDSIO
  25.      VME board provides six serial ports; see _c_d_s_i_o(7) for more information.
  26.  
  27.      Special files for the serial ports exist in the /_d_e_v directory. These
  28.      files are named ttttttttyyyy<ttttyyyyppppeeee><ppppoooorrrrttttnnnnoooo>, where ttttyyyyppppeeee is one or more characters
  29.      indicating the type of interface to the hardware that this file provides,
  30.      and ppppoooorrrrttttnnnnoooo is a number identifying the physical port. The descriptions
  31.      below indicate among other things which hardware signals are used by each
  32.      port type. For more details on this see SOFTWARE USAGE below. Currently
  33.      supported types include:
  34.  
  35.      _dddd    e.g. ttyd1. This is the most basic serial port type. It supports
  36.           TD/RD only.
  37.  
  38.      _mmmm    e.g. ttym1. This port type provides modem control. It supports TD/RD
  39.           and DCD/DTR.
  40.  
  41.      _ffff    e.g. ttyf1. This port type provides modem and flow control. It
  42.           supports TD/RD, DCD/DTR and RTS/CTS.
  43.  
  44.      The following types are supported on O2, OCTANE, Origin2000/200, Onyx2
  45.      and Challenge/Onyx systems:
  46.  
  47.      _cccc    e.g. ttyc1. This port type provides a raw character device interface
  48.           to the hardware. It is intended for applications which wish to do
  49.           bulk data transfer with minimal overhead and no data interpretation.
  50.           Since this is not a streams device and no line discipline exists,
  51.           streams or line discipline related ioctl commands may fail or
  52.           silently have no effect. See cserialio(7) for details.  This port
  53.           type supports only TD/RD by default but RTS/CTS flow control may be
  54.           enabled via ioctl if the hardware supports it.
  55.  
  56.      _4444_dddd   e.g. tty4d1. This port type enables RS422 (Appletalk) mode. It uses
  57.           TxD+/-, RxD+/-. On Challenge/Onyx, every 4th port (tty4d4, tty4d8,
  58.           etc.) is hardwired to RS422 and other ports are hardwired to RS232,
  59.           so this port type only exists for every 4th port.
  60.  
  61.  
  62.  
  63.                                                                         PPPPaaaaggggeeee 1111
  64.  
  65.  
  66.  
  67.  
  68.  
  69.  
  70. sssseeeerrrriiiiaaaallll((((7777))))                                                            sssseeeerrrriiiiaaaallll((((7777))))
  71.  
  72.  
  73.  
  74.      _4444_ffff   e.g. tty4f1. This port type enables RS422 (Appletalk) mode including
  75.           the handshake signals. It uses TxD+/-, RxD+/-, HSKo and HSKi. On
  76.           Challenge/Onyx, every 4th port (tty4d4, tty4d8, etc.) is hardwired
  77.           to RS422 and other ports are hardwired to RS232, so this port type
  78.           only exists for every 4th port.
  79.  
  80.      _mmmm_iiii_dddd_iiii e.g. ttymidi1. This port type provides a midi interface to the
  81.           serial device. See midi(3).
  82.  
  83.      The following type is supported on O2, OCTANE, Onyx2 and Origin2000/200
  84.      systems:
  85.  
  86.      _uuuu_ssss   e.g. ttyus1. This port type provides a user mapped interface to the
  87.           hardware, allowing reading and writing of bytes without any system
  88.           call overhead. Use of this port requires installation of the
  89.           react.sw.usio subsystem of REACT/Pro. See usio(3) for details.
  90.  
  91.      The ppppoooorrrrttttnnnnoooo component of the tty filename identifies the actual hardware
  92.      accessed by the device file. All tty files with the same port number
  93.      access the same hardware, i.e. ttyd1, ttyc1 and ttymidi1 all access the
  94.      same physical port. A given tty device may be opened any number of times,
  95.      but only one interface type may be opened to the same physical port at a
  96.      time, e.g. if ttyd1 is open, access will be denied to ttyf1 or ttyc1.
  97.  
  98.      On Onyx2 systems with console set to d, and on Origin2000 and Origin200
  99.      systems, the console port and its twin are guaranteed to be ports 1 and
  100.      2, all other ports are dynamically assigned port numbers as per the whims
  101.      of ioconfig(1). It may be necessary to obtain the absolute path of the
  102.      port in the filesystem by resolving links until a true device is found in
  103.      order to determine where on the machine the port is actually located.
  104.  
  105. CCCCOOOONNNNNNNNEEEECCCCTTTTOOOORRRRSSSS AAAANNNNDDDD PPPPIIIINNNN AAAASSSSSSSSIIIIGGGGNNNNMMMMEEEENNNNTTTTSSSS
  106.      There are five different types of connectors found on various 4D models.
  107.      The DB-9 male serial port connectors on O2, OCTANE, Onyx2, Origin2000 and
  108.      Origin200 systems have the following IBM(R) PC/AT(tm)-like pin
  109.      assignments:
  110.  
  111.                                 -------------------
  112.                                 \  1  2  3  4  5  /
  113.                                  \   6  7  8  9  /
  114.                                   ---------------
  115.  
  116.                          Pin   Name   Description
  117.                          ________________________________
  118.                           1    DCD    Data Carrier Detect
  119.                           2    RD     Receive Data
  120.                           3    TD     Transmit Data
  121.                           4    DTR    Data Terminal Ready
  122.                           5    GND    Signal Ground
  123.                           6    -      reserved
  124.                           7    RTS    Request To Send
  125.                              |||||||||
  126.  
  127.  
  128.  
  129.  
  130.  
  131.  
  132.                                     |||||||||
  133.  
  134.  
  135.  
  136.  
  137.  
  138.  
  139.  
  140.  
  141.  
  142.  
  143.  
  144.  
  145.                                                                         PPPPaaaaggggeeee 2222
  146.  
  147.  
  148.  
  149.  
  150.  
  151.  
  152. sssseeeerrrriiiiaaaallll((((7777))))                                                            sssseeeerrrriiiiaaaallll((((7777))))
  153.  
  154.  
  155.  
  156.                           8    CTS    Clear To Send
  157.                           9    -      reserved
  158.                              ||
  159.                                     ||
  160.  
  161.  
  162.      The ports on OCTANE, Onyx2, Origin2000 and Origin200 systems can be set
  163.      by software to an Appletalk-compatible RS-422-like mode, in which they
  164.      have the following pin assignments:
  165.  
  166.                            Pin   Name   Description
  167.                            _____________________________
  168.                             1    -      reserved
  169.                             2    RxD-   Receive Data -
  170.                             3    TxD-   Transmit Data -
  171.                             4    TxD+   Transmit Data +
  172.                             5    GND    Signal Ground
  173.                             6    RxD+   Receive Data +
  174.                             7    HSKo   Output Handshake
  175.                             8    HSKi   Input Handshake
  176.                             9    -      reserved
  177.                                |||||||||||
  178.  
  179.  
  180.  
  181.  
  182.  
  183.  
  184.  
  185.  
  186.                                       |||||||||||
  187.  
  188.  
  189.  
  190.  
  191.  
  192.  
  193.  
  194.  
  195.  
  196.  
  197.      The DB-9 female serial port connectors, which are found on the CHALLENGE
  198.      and Onyx systems, have the following pin assignments.
  199.  
  200.                                 -------------------
  201.                                 \  5  4  3  2  1  /
  202.                                  \   9  8  7  6  /
  203.                                   ---------------
  204.  
  205.                          Pin   Name   Description
  206.                          ________________________________
  207.                           2    TD     Transmit Data
  208.                           3    RD     Receive Data
  209.                           4    RTS    Request To Send
  210.                           5    CTS    Clear To Send
  211.                           7    SG     Signal Ground
  212.                           8    DCD    Data Carrier Detect
  213.                           9    DTR    Data Terminal Ready
  214.                              |||||||||
  215.  
  216.  
  217.  
  218.  
  219.  
  220.  
  221.                                     |||||||||
  222.  
  223.  
  224.  
  225.  
  226.  
  227.  
  228.  
  229.  
  230.      The CHALLENGE and Onyx systems provide an RS-422 port.  This RS-422 port
  231.      uses a DB-9 female serial connector and has the following pin
  232.      assignments.
  233.  
  234.                          Pin   Name   Description
  235.                          ________________________________
  236.                           1    DTR    Data Terminal Ready
  237.                           2    TxD-   Transmit Data -
  238.                           3    RxD-   Receive Data -
  239.                           4    DCD    Data Carrier Detect
  240.                           5    CTS    Clear To Send
  241.                           6    SG     Signal Ground
  242.                           7    TxD+   Transmit Data +
  243.                           8    RxD+   Receive Data +
  244.                           9    RTS    Request to send
  245.                              |||||||||||
  246.  
  247.  
  248.  
  249.  
  250.  
  251.  
  252.  
  253.  
  254.                                     |||||||||||
  255.  
  256.  
  257.  
  258.  
  259.  
  260.  
  261.  
  262.  
  263.  
  264.  
  265.  
  266.  
  267.  
  268.  
  269.                                                                         PPPPaaaaggggeeee 3333
  270.  
  271.  
  272.  
  273.  
  274.  
  275.  
  276. sssseeeerrrriiiiaaaallll((((7777))))                                                            sssseeeerrrriiiiaaaallll((((7777))))
  277.  
  278.  
  279.  
  280.                             |
  281.                                     |
  282.  
  283.      In order to support peripherals that draw power from the host system, the
  284.      CHALLENGE and Onyx systems provide two powered-peripheral serial ports.
  285.      These ports have a DIN-8 connector.  The powered ports share the tty2 and
  286.      tty3 signal lines with the standard DB-9 connectors; if the DB-9
  287.      connector for tty2 is already in use, you cannot use the powered
  288.      peripheral connector for tty2.  Similarly, if tty3's DB-9 connector is
  289.      connected to a peripheral, the powered peripheral port connected to the
  290.      tty3 signal lines cannot also be used.  The powered peripheral ports have
  291.      the following pin assignments.
  292.  
  293.                                       __---__
  294.                                      /   2   \
  295.                                     /4       5\
  296.                                    /           \
  297.                                   ( 1    8    3 )
  298.                                    \           /
  299.                                     \ 6     7 /
  300.                                      ---___---
  301.  
  302.                         Pin   Name     Description
  303.                         __________________________________
  304.                          1    DTR      Data Terminal Ready
  305.                          2    CTS      Clear To Send
  306.                          3    STEREO   Stereo field sync
  307.                          4    RD       Receive Data
  308.                          5    TD       Transmit Data
  309.                          6    SG       Signal Ground
  310.                          7    GND      Ground point
  311.                          8    V10P     10V supply
  312.                             ||||||||||
  313.  
  314.  
  315.  
  316.  
  317.  
  318.  
  319.  
  320.                                      ||||||||||
  321.  
  322.  
  323.  
  324.  
  325.  
  326.  
  327.  
  328.  
  329.  
  330.      The DIN-8 serial port connectors on the Indigo, Indy, Indigo and the
  331.      MENET 4-Enet, 6-serial board (XT-FE-4TX-6A) have the following pin
  332.      assignments.
  333.  
  334.                                      ---------
  335.                                     / 8  7  6 \
  336.                                    (  5  4  3  )
  337.                                     \  2   1  /
  338.                                      ---------
  339.  
  340.                       4D Compatible Pin Assignments (RS-232)
  341.                      _________________________________________
  342.                       Pin     Name      Description
  343.                      _________________________________________
  344.                        1      DTR       Data Terminal Ready
  345.                        2      CTS       Clear To Send
  346.                        3      TD        Transmit Data
  347.                        4      SG        Signal Ground
  348.                        5      RD        Receive Data
  349.                        6      RTS       Request To Send
  350.                             ||||||||
  351.  
  352.  
  353.  
  354.  
  355.  
  356.                                       ||||||||
  357.  
  358.  
  359.  
  360.  
  361.  
  362.  
  363.  
  364.  
  365.  
  366.  
  367.  
  368.                                                                         PPPPaaaaggggeeee 4444
  369.  
  370.  
  371.  
  372.  
  373.  
  374.  
  375. sssseeeerrrriiiiaaaallll((((7777))))                                                            sssseeeerrrriiiiaaaallll((((7777))))
  376.  
  377.  
  378.  
  379.                        7      DCD       Data Carrier Detect
  380.                        8      SG        Signal Ground
  381.                             ||
  382.                                       ||
  383.  
  384.                  Macintosh SE Compatible Pin Assignments (RS-422)
  385.                  _________________________________________________
  386.                  Pin    Name    Description
  387.                  _________________________________________________
  388.                   1     HSKo    Output Handshake
  389.                   2     HSKi    Input Handshake Or External Clock
  390.                   3     TxD-    Transmit Data -
  391.                   4     GND     Signal Ground
  392.                   5     RxD-    Receive Data -
  393.                   6     TxD+    Transmit Data +
  394.                   7     GPi     General Purpose Input
  395.                   8     RxD+    Receive Data +
  396.                       ||||||||||
  397.  
  398.  
  399.  
  400.  
  401.  
  402.  
  403.  
  404.                               ||||||||||
  405.  
  406.  
  407.  
  408.  
  409.  
  410.  
  411.  
  412.  
  413.  
  414. SSSSOOOOFFFFTTTTWWWWAAAARRRREEEE UUUUSSSSAAAAGGGGEEEE
  415.      The set of signals that are actually used depends upon which form of the
  416.      device was opened.  If the ttttttttyyyydddd name was used, only TTTTDDDD, RRRRDDDD, and SSSSGGGG
  417.      signals are meaningful.  These three signals are typically used with
  418.      "dumb" devices that either do not need any sort of data flow control or
  419.      use software flow control (see the description of the iiiixxxxoooonnnn, iiiixxxxaaaannnnyyyy, and
  420.      iiiixxxxooooffffffff options in _s_t_t_y(1) for more information on setting up software flow
  421.      control).  If the ttttttttyyyymmmm device is used, the DDDDCCCCDDDD, and DDDDTTTTRRRR signals are also
  422.      used.  These signals provide a two way handshake for establishing and
  423.      breaking a communication link with another device and are normally used
  424.      when connecting via a modem.  When the port is initially opened, the host
  425.      asserts the DDDDTTTTRRRR line and waits for the DDDDCCCCDDDD line to become active.  If the
  426.      port is opened with the OOOO____NNNNDDDDEEEELLLLAAAAYYYY flag, the open succeeds even if the DDDDCCCCDDDD
  427.      line is not active.  A hangup condition occurs if the DDDDCCCCDDDD line
  428.      transitions from active to inactive.  See _o_p_e_n(2), and _t_e_r_m_i_o(7) for more
  429.      information.  If the ttttttttyyyyffff device is used, all of the signals are used.
  430.      The additional signals provide for full hardware flow control between the
  431.      host and the remote device.  The RRRRTTTTSSSS line is asserted by the host
  432.      whenever it is capable of receiving more data.  The CCCCTTTTSSSS line is sampled
  433.      before data is transmitted and if it is not active, the host suspends
  434.      output until it is.
  435.  
  436.      The DIN-8 serial port connectors on the Indy, Indigo and MENET 4-Enet,
  437.      6-serial board (XT-FE-4TX-6A) can be used to communicate with serial
  438.      devices using RS-422 protocol.  User can use the stream ioctl commands,
  439.      SSSSIIIIOOOOCCCC____EEEEXXXXTTTTCCCCLLLLKKKK and SSSSIIIIOOOOCCCC____RRRRSSSS444422222222, defined in /_u_s_r/_i_n_c_l_u_d_e/_s_y_s/_z_8_5_3_0._h to switch
  440.      between internal/external clock and RS-232/RS-422 protocols.  Another
  441.      command that can be useful is SSSSIIIIOOOOCCCC____IIIITTTTIIIIMMMMEEEERRRR; it informs the driver how long
  442.      it should buffer up input data, in clock ticks, before sending them
  443.      upstream.  Data can sometimes be sent upstream before, but never after,
  444.      this time limit.  This feature reduces the cpu cost of receiving large
  445.      amounts of data by sending data upstream in large chunks.  This duration
  446.      can also be configured into the kernel by tuning the duart_rsrv_duration
  447.      variable.  On Origin, Onyx2, O2 and Octane systems, the serial hardware
  448.      sets an input timer based on the value passed in through SIOC_ITIMER. For
  449.      soft flow control, this input timer may result in excessively slow
  450.      response to an XOFF request since an XOFF char is not detected by the
  451.  
  452.  
  453.  
  454.                                                                         PPPPaaaaggggeeee 5555
  455.  
  456.  
  457.  
  458.  
  459.  
  460.  
  461. sssseeeerrrriiiiaaaallll((((7777))))                                                            sssseeeerrrriiiiaaaallll((((7777))))
  462.  
  463.  
  464.  
  465.      software until the hardware timer expires. If soft flow control skid is
  466.      unacceptably large, it may be necessary to reduce the latency of the
  467.      hardware input timer by reducing the value passed to SIOC_ITIMER.
  468.  
  469. SSSSUUUUPPPPPPPPOOOORRRRTTTTEEEEDDDD SSSSPPPPEEEEEEEEDDDDSSSS
  470.      The serial ports of all SGI systems support several standard rates up
  471.      through 38400 bps (see _t_e_r_m_i_o(_7) for these standard rates). The serial
  472.      ports on O2, OCTANE, Origin2000, Onyx2 and Origin200 systems also support
  473.      bit rates up through 115200 bps, including the following rates:
  474.  
  475.                                   31250   57600
  476.                                   76800   115200
  477.  
  478.      Many other rates, up to 460800, can be set.  The accuracy of actual baud
  479.      rate set is guaranteed to be within 2.5% of the desired rate.  If this
  480.      condition cannot be met, the command (ioctl or stty) will fail.  However,
  481.      performance at baud rates above 115200 is not guaranteed, and their use
  482.      is not officially supported.
  483.  
  484.      At baud rates above 38400, cable length and quality become quite
  485.      important.  These rates are more likely to work in RS-422 mode, on
  486.      systems that support it.
  487.  
  488. CCCCHHHHAAAALLLLLLLLEEEENNNNGGGGEEEE AAAANNNNDDDD OOOONNNNYYYYXXXX LLLL////XXXXLLLL PPPPOOOORRRRTTTT CCCCOOOONNNNFFFFIIIIGGGGUUUURRRRAAAATTTTIIIIOOOONNNN
  489.      By default, Onyx and CHALLENGE L/XL systems enable only the serial ports
  490.      of the master IO4.  To enable the serial ports on other IO4 boards, a
  491.      vector line must be added for the epcserial device to
  492.      /_v_a_r/_s_y_s_g_e_n/_s_y_s_t_e_m/_i_r_i_x._s_m.  The following vector line configures the
  493.      serial ports on the IO4 in slot 13 as tty45, tty46, and tty47:
  494.  
  495.           VECTOR: bustype=EPC module=epcserial unit=1 slot=13
  496.  
  497.      The first two options (bustype and module) are mandatory and tell
  498.      _l_b_o_o_t(1M) that you're configuring serial ports.  The uuuunnnniiiitttt option
  499.      specifies which set of tty names should be used for this set of ports:
  500.      unit 1 corresponds to the logical devices tty45, tty46, and tty47; unit 2
  501.      represents devices tty49, tty50, and tty51; unit 3 specifies devices
  502.      tty53, tty54, and tty55.  Finally, the ssssllllooootttt option indicates which IO4
  503.      board contains the ports that should be mapped.  Each board must have its
  504.      own vector line.  Configuring one IO4 board's serial ports has no effect
  505.      on any of the other boards.  After iiiirrrriiiixxxx....ssssmmmm has been updated, the
  506.      _a_u_t_o_c_o_n_f_i_g(1M) command should be issued to reconfigure the kernel.  It
  507.      may also be necessary to execute _M_A_K_E_D_E_V(1M) in order to build device
  508.      files for the new ports.
  509.  
  510.      If the system is unable to honor the VECTOR line for some reason (if, for
  511.      example, the specified slot is invalid), a warning message is written to
  512.      /_v_a_r/_a_d_m/_S_Y_S_L_O_G.  These warning messages contain the string eeeeppppccccsssseeeerrrriiiiaaaallll, in
  513.      order to facilitate finding them with commands like _g_r_e_p(1).  Because the
  514.      console port has not been initialized when these messages are issued, the
  515.      kernel is unable to display the warning on the console.
  516.  
  517.  
  518.  
  519.  
  520.                                                                         PPPPaaaaggggeeee 6666
  521.  
  522.  
  523.  
  524.  
  525.  
  526.  
  527. sssseeeerrrriiiiaaaallll((((7777))))                                                            sssseeeerrrriiiiaaaallll((((7777))))
  528.  
  529.  
  530.  
  531.      Only the master IO4 provides an RS-422 port (tty4).  Additional IO4
  532.      boards support three RS-232 serial ports only.  To allow for future
  533.      expansion, however, space was left in the serial port namespace for the
  534.      additional RS-422 ports.  For this reason, there is no actual device
  535.      associated with tty48, tty52, and tty56.
  536.  
  537. FFFFIIIILLLLEEEESSSS
  538.      /dev/tty[dmf][1-4,45-56]
  539.      /usr/include/sys/z8530.h
  540.      /dev/MAKEDEV
  541.      /var/sysgen/system
  542.  
  543. SSSSEEEEEEEE AAAALLLLSSSSOOOO
  544.      system(4), asoser(7), cdsio(7), keyboard(7), streamio(7), termio(7),
  545.      termios(3), cserialio(7), usio(3).
  546.  
  547.  
  548.  
  549.  
  550.  
  551.  
  552.  
  553.  
  554.  
  555.  
  556.  
  557.  
  558.  
  559.  
  560.  
  561.  
  562.  
  563.  
  564.  
  565.  
  566.  
  567.  
  568.  
  569.  
  570.  
  571.  
  572.  
  573.  
  574.  
  575.  
  576.  
  577.  
  578.  
  579.  
  580.  
  581.  
  582.  
  583.  
  584.  
  585.  
  586.                                                                         PPPPaaaaggggeeee 7777
  587.  
  588.  
  589.  
  590.